// 用于封装login所有请求
import request from '@/utils/request'
export const getPicCode = () => {
  return request.get('/captcha/image')
}
export const getCode = (captchaCode, captchaKey, mobile) => {
  return request.post('/captcha/sendSmsCaptcha', {
    form: {
      captchaCode, captchaKey, mobile
    }
  })
}

// 登录
export const login = (mobile, smsCode) => {
  return request.post('/passport/login', {
    form: {
      isParty: false,
      mobile,
      partyData: {},
      smsCode
    }
  })
}